package org.jeecg.modules.demo.sy.mapper;

import org.jeecg.modules.demo.sy.entity.Device;
import org.jeecg.modules.demo.sy.entity.Mode1;
import org.jeecg.modules.demo.sy.entity.Mode2;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface DeviceMapper {
    Device findDeviceById(int deviceId);

    List<Device> findAllDevices();

    Integer findDevicesAmount();

    Integer findDevicesAmountByStatusId(int deviceStatusId);

    List<Mode1> findDevicesTypeAndAmount();

    List<Mode1> findDevicesStatusAndAmount();

    void updateDevicesStatus(int deviceId, int nowDeviceStatusId, int nowFaultTypeId);

    List<Mode2> findAreaDevicesAmountAndFaultDeviceAmount();
}
